//
//  BORefreshHeader.m
//  coffee1029
//
//  Created by liwei on 15/12/15.
//  Copyright © 2015年 liwei. All rights reserved.
//

#import "BORefreshHeader.h"

@implementation BORefreshHeader

+ (instancetype)mt_headerWithRefreshingBlock:(MJRefreshComponentRefreshingBlock)refreshingBlock {
    BORefreshHeader *head = [super headerWithRefreshingBlock:refreshingBlock];
    if (head) {
        head.backgroundColor = [UIColor clearColor];
        [head setTitle:@"下拉刷新" forState:MJRefreshStateIdle];
        [head setTitle:@"释放立即刷新" forState:MJRefreshStatePulling];
        [head setTitle:@"加载中" forState:MJRefreshStateRefreshing];
//        [head set]
        head.lastUpdatedTimeLabel.hidden = YES;
    }
    return head;
}
+ (instancetype)mt_collectHeaderWithRefreshingBlock:(MJRefreshComponentRefreshingBlock)refreshingBlock {
    BORefreshHeader *head = [super headerWithRefreshingBlock:refreshingBlock];
    if (head) {
        head.backgroundColor = [UIColor clearColor];
        [head setTitle:@"下拉刷新" forState:MJRefreshStateIdle];
        [head setTitle:@"释放立即刷新" forState:MJRefreshStatePulling];
        [head setTitle:@"加载中" forState:MJRefreshStateRefreshing];
        //        [head set]
        head.lastUpdatedTimeLabel.hidden = YES;
        head.type = CollectHeaderType;
        head.cov_headerViewH = DEVW / 2;
    }
    return head;
}

@end
